import React, { useState } from 'react';
import { Button, Modal } from 'antd';
const Delmodal = (props) => {
    console.log(props);
  const [isModalOpen, setIsModalOpen] = useState(true);
  const showModal = () => {
  
    setIsModalOpen(true);
  };
  const handleOk = () => {
    props.delsurefn({
        sure:false,
        isok:"确定"
    })
  };
  const handleCancel = () => {
   props.delsurefn({
       sure:false,
       isok:"取消"
   })
  };
  return (
    <>
      <Button type="primary" onClick={showModal}>
        Open Modal
      </Button>
      <Modal title="Basic Modal" open={props.ismodelopen} onOk={handleOk} onCancel={handleCancel}>
        <p>您确定要删除吗?</p>
      </Modal>
    </>
  );
};
export default Delmodal;